<template>
	<view class="container" style="padding: 20rpx 30rpx;">
		<view style="font-size: 36rpx;font-weight: bold;color: #000">{{articleDetail.title}}</view>
		<view style="margin-top: 20rpx;display: flex;flex-direction: row;align-items: center;">
			<view style="color: #999;">{{$time.dateFormat('YYYY-MM-DD hh:mm',articleDetail.createTime)}}</view>
			<view style="color: #999;margin-left: 40rpx;">阅读 {{articleDetail.readUserCount}}</view>
		</view>
		<view style="margin-top: 40rpx;">
			<u-parse :content="articleDetail.content" :selectable="true"></u-parse>
		</view>
	</view>
</template>

<script>
	import {common} from '@/api/common.js'
	export default{
		components: {},
		data() {
			return {
				page: 1,
				size: 20,
				dataList: [],
				showEmpty: false,
				isLastPage: false,
				obj_id: '',
				articleDetail: {}
			}
		},
		onLoad() {
			this.obj_id = this.$Route.query.obj_id
			this.getData()
		},
		methods:{
			getData() {
				common.operateActionPost('system/article/getItemById/', {obj_id: this.obj_id}).then(res => {
					if (res.data.code == 10000) {
					  this.articleDetail = res.data.data
					}
				});
			},
		}
	}
</script>

<style scoped lang="scss">
	
</style>
